package com.shuziren.entity;

import cn.hutool.json.JSON;
import cn.hutool.json.JSONArray;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableField;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.shuziren.config.JsonArrayTypeHandler;
import lombok.Data;

import java.util.Date;
import java.util.List;

@TableName(value = "interview_positions",autoResultMap = true)
@Data
public class InterviewPosition {
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    @TableField("position_name")
    private String positionName;

    @TableField("department")
    private String department;

    @TableField("position_level")
    private String positionLevel;

    @TableField("job_description")
    private String jobDescription;

    @TableField("job_requirements")
    private String jobRequirements;

    @TableField(value = "required_skills",typeHandler = JsonArrayTypeHandler.class)
    private JSONArray requiredSkills;

    @TableField("status")
    private Integer status;

    @TableField("headcount")
    private Integer headcount;


    @TableField("created_at")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date createdAt;


    @TableField("updated_at")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date updatedAt;
}